package com.example.myplugintest;


import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;

public class TestActivity extends Activity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_test);
    }


    public void startActivity(View view) {
        Class<?> aClass=null;
        try {
            aClass = Class.forName("com.test.my.DnActivity");
        } catch (ClassNotFoundException e) {
            e.printStackTrace();
        }
        if(aClass!=null){
            Intent intent=new Intent();
            intent.setClass(TestActivity.this,aClass);
            startActivity(intent);
        }
    }

    public void installApp(View view) {
        ApkUtil.getInstance().loadDex(TestActivity.this,"dnplugin-debug.apk");
    }
}